package com.yoomiito.app.model.order;

import android.os.Parcel;
import android.os.Parcelable;

import com.yoomiito.app.model.bean.WuliuInfo;

import java.util.List;

public class OrderDetailInfo implements Parcelable {


    /**
     * product_type : 0
     * id : 4642924961970304
     * is_rebate : 1
     * ctime : 2019-02-24 20:37:58
     * product_name : 法国原瓶原装进口波尔多AOC芙诺兰庄园珍酿干红葡萄酒750ML*4支
     * sn : 4642924961904768
     * amount_paid : 369.00
     * amount : 369.00
     * shipped_time : 2019-02-25 13:51:54
     * confirm_time : 2019-04-27 17:02:12
     * company_code : yuantong
     * track_no : 820566568147
     * status : 4
     * consignee : 燕子
     * area_name : 甘肃省武威市天祝藏族自治县
     * mobile : 18199357860
     * address : 甘肃省武威市天祝藏族自治县甘肃省武威市小北街57号
     * note :
     * product_img : https://mimitao-cdn.aijiamai.com/FguI39TFluMy2BZaasWTL8FJjEjL
     * expressState : 1
     * express_company : 圆通
     * expressInfo : [{"time":"2019-04-28 06:04:56","ftime":"2019-04-28 06:04:56","context":"快件已发往 {广东省深圳市宝安区固戍公司}"},{"time":"2019-04-28 05:47:23","ftime":"2019-04-28 05:47:23","context":"快件已到达 [深圳转运中心]"},{"time":"2019-04-28 02:48:17","ftime":"2019-04-28 02:48:17","context":"快件已发往 [深圳转运中心]"},{"time":"2019-04-28 02:46:19","ftime":"2019-04-28 02:46:19","context":"快件已到达 [虎门转运中心]"},{"time":"2019-04-26 22:32:15","ftime":"2019-04-26 22:32:15","context":"快件已发往 [虎门转运中心]"},{"time":"2019-04-26 22:29:06","ftime":"2019-04-26 22:29:06","context":"快件已到达 [嘉兴转运中心]"},{"time":"2019-04-26 19:00:35","ftime":"2019-04-26 19:00:35","context":"快件已发往 [嘉兴转运中心]"},{"time":"2019-04-25 19:13:29","ftime":"2019-04-25 19:13:29","context":"{浙江省嘉兴市海盐县公司} 李光兵 (18069696077) 已收件"}]
     * statueDes : 已结算
     */

    private int product_type;
    private String id;
    private int is_rebate;
    private String ctime;
    private String product_name;
    private String sn;
    private String amount_paid; //实付款
    private String amount;      //
    private String shipped_time;
    private String confirm_time;
    private String company_code;
    private String trackNo;
    private int status;
    private String consignee;
    private String area_name;
    private String mobile;
    private String address;
    private String note;
    private String product_img;
    private int expressState;
    private String express_company;
    private String statueDes;
    private List<WuliuInfo> express;
    private String num;
    private boolean cancel_button;
    private String pay_type;
    private String balance_paid;
    private String cash_paid;
    private int order_type;
    private List<OrderDetailGoods> order_detail;
    private String paid_time;
    private String yo_money_paid;
    private String order_total;//订单总价
    private List<String> acode;//

    public String productName;
    public String statusStr;
    public String banner;
    public String price;
    public String totalMoney;
    public String name;
    public int display;
    public String province;
    public String city;
    public String county;
    public String shippedTime;
    public String confirmTime;
    private String deduction_account_paid;//可抵扣余额
    public boolean isCancel_button() {
        return cancel_button;
    }

    public void setCancel_button(boolean cancel_button) {
        this.cancel_button = cancel_button;
    }

    public int getProduct_type() {
        return product_type;
    }

    public void setProduct_type(int product_type) {
        this.product_type = product_type;
    }

    public String getId() {
        return id;
    }

    public void setId(String id) {
        this.id = id;
    }

    public int getIs_rebate() {
        return is_rebate;
    }

    public void setIs_rebate(int is_rebate) {
        this.is_rebate = is_rebate;
    }

    public String getCtime() {
        return ctime;
    }

    public void setCtime(String ctime) {
        this.ctime = ctime;
    }

    public String getProduct_name() {
        return product_name;
    }

    public void setProduct_name(String product_name) {
        this.product_name = product_name;
    }

    public String getSn() {
        return sn;
    }

    public void setSn(String sn) {
        this.sn = sn;
    }

    public String getAmount_paid() {
        return amount_paid;
    }

    public void setAmount_paid(String amount_paid) {
        this.amount_paid = amount_paid;
    }

    public String getAmount() {
        return amount;
    }

    public void setAmount(String amount) {
        this.amount = amount;
    }

    public String getShipped_time() {
        return shipped_time;
    }

    public void setShipped_time(String shipped_time) {
        this.shipped_time = shipped_time;
    }

    public String getConfirm_time() {
        return confirm_time;
    }

    public void setConfirm_time(String confirm_time) {
        this.confirm_time = confirm_time;
    }

    public String getCompany_code() {
        return company_code;
    }

    public void setCompany_code(String company_code) {
        this.company_code = company_code;
    }

    public String getTrack_no() {
        return trackNo;
    }

    public void setTrack_no(String track_no) {
        this.trackNo = track_no;
    }

    public int getStatus() {
        return status;
    }

    public void setStatus(int status) {
        this.status = status;
    }

    public String getConsignee() {
        return consignee;
    }

    public void setConsignee(String consignee) {
        this.consignee = consignee;
    }

    public String getArea_name() {
        return area_name;
    }

    public void setArea_name(String area_name) {
        this.area_name = area_name;
    }

    public String getMobile() {
        return mobile;
    }

    public void setMobile(String mobile) {
        this.mobile = mobile;
    }

    public String getAddress() {
        return address;
    }

    public void setAddress(String address) {
        this.address = address;
    }

    public String getNote() {
        return note;
    }

    public void setNote(String note) {
        this.note = note;
    }

    public String getProduct_img() {
        return product_img;
    }

    public void setProduct_img(String product_img) {
        this.product_img = product_img;
    }

    public int getExpressState() {
        return expressState;
    }

    public void setExpressState(int expressState) {
        this.expressState = expressState;
    }

    public String getExpress_company() {
        return express_company;
    }

    public void setExpress_company(String express_company) {
        this.express_company = express_company;
    }

    public String getStatueDes() {
        return statueDes;
    }

    public void setStatueDes(String statueDes) {
        this.statueDes = statueDes;
    }

    public List<WuliuInfo> getExpressInfo() {
        return express;
    }

    public void setExpressInfo(List<WuliuInfo> expressInfo) {
        this.express = expressInfo;
    }

    public String getNum() {
        return num;
    }

    public void setNum(String num) {
        this.num = num;
    }

    public String getPay_type() {
        return pay_type;
    }

    public void setPay_type(String pay_type) {
        this.pay_type = pay_type;
    }

    public String getBalance_paid() {
        return balance_paid;
    }

    public void setBalance_paid(String balance_paid) {
        this.balance_paid = balance_paid;
    }

    public String getCash_paid() {
        return cash_paid;
    }

    public void setCash_paid(String cash_paid) {
        this.cash_paid = cash_paid;
    }

    public int getOrder_type() {
        return order_type;
    }

    public void setOrder_type(int order_type) {
        this.order_type = order_type;
    }

    public List<OrderDetailGoods> getOrder_detail() {
        return order_detail;
    }

    public void setOrder_detail(List<OrderDetailGoods> order_detail) {
        this.order_detail = order_detail;
    }

    public String getPaid_time() {
        return paid_time;
    }

    public void setPaid_time(String paid_time) {
        this.paid_time = paid_time;
    }


    public String getYo_money_paid() {
        return yo_money_paid;
    }

    public void setYo_money_paid(String yo_money_paid) {
        this.yo_money_paid = yo_money_paid;
    }

    public String getOrder_total() {
        return order_total;
    }

    public void setOrder_total(String order_total) {
        this.order_total = order_total;
    }

    public List<String> getAcode() {
        return acode;
    }

    public void setAcode(List<String> acode) {
        this.acode = acode;
    }

    public String getDeduction_account_paid() {
        return deduction_account_paid;
    }

    public void setDeduction_account_paid(String deduction_account_paid) {
        this.deduction_account_paid = deduction_account_paid;
    }

    @Override
    public int describeContents() {
        return 0;
    }

    @Override
    public void writeToParcel(Parcel dest, int flags) {
        dest.writeInt(this.product_type);
        dest.writeString(this.id);
        dest.writeInt(this.is_rebate);
        dest.writeString(this.ctime);
        dest.writeString(this.product_name);
        dest.writeString(this.sn);
        dest.writeString(this.amount_paid);
        dest.writeString(this.amount);
        dest.writeString(this.shipped_time);
        dest.writeString(this.confirm_time);
        dest.writeString(this.company_code);
        dest.writeString(this.trackNo);
        dest.writeInt(this.status);
        dest.writeString(this.consignee);
        dest.writeString(this.area_name);
        dest.writeString(this.mobile);
        dest.writeString(this.address);
        dest.writeString(this.note);
        dest.writeString(this.product_img);
        dest.writeInt(this.expressState);
        dest.writeString(this.express_company);
        dest.writeString(this.statueDes);
        dest.writeTypedList(this.express);
        dest.writeString(this.num);
        dest.writeByte(this.cancel_button ? (byte) 1 : (byte) 0);
        dest.writeString(this.pay_type);
        dest.writeString(this.balance_paid);
        dest.writeString(this.cash_paid);
        dest.writeInt(this.order_type);
        dest.writeTypedList(this.order_detail);
        dest.writeString(this.paid_time);
        dest.writeString(this.yo_money_paid);
        dest.writeString(this.order_total);
        dest.writeStringList(this.acode);
        dest.writeString(deduction_account_paid);
    }

    public OrderDetailInfo() {
    }

    protected OrderDetailInfo(Parcel in) {
        this.product_type = in.readInt();
        this.id = in.readString();
        this.is_rebate = in.readInt();
        this.ctime = in.readString();
        this.product_name = in.readString();
        this.sn = in.readString();
        this.amount_paid = in.readString();
        this.amount = in.readString();
        this.shipped_time = in.readString();
        this.confirm_time = in.readString();
        this.company_code = in.readString();
        this.trackNo = in.readString();
        this.status = in.readInt();
        this.consignee = in.readString();
        this.area_name = in.readString();
        this.mobile = in.readString();
        this.address = in.readString();
        this.note = in.readString();
        this.product_img = in.readString();
        this.expressState = in.readInt();
        this.express_company = in.readString();
        this.statueDes = in.readString();
        this.express = in.createTypedArrayList(WuliuInfo.CREATOR);
        this.num = in.readString();
        this.cancel_button = in.readByte() != 0;
        this.pay_type = in.readString();
        this.balance_paid = in.readString();
        this.cash_paid = in.readString();
        this.order_type = in.readInt();
        this.order_detail = in.createTypedArrayList(OrderDetailGoods.CREATOR);
        this.paid_time = in.readString();
        this.yo_money_paid = in.readString();
        this.order_total = in.readString();
        this.acode = in.createStringArrayList();
        this.deduction_account_paid = in.readString();
    }

    public static final Creator<OrderDetailInfo> CREATOR = new Creator<OrderDetailInfo>() {
        @Override
        public OrderDetailInfo createFromParcel(Parcel source) {
            return new OrderDetailInfo(source);
        }

        @Override
        public OrderDetailInfo[] newArray(int size) {
            return new OrderDetailInfo[size];
        }
    };
}
